Build docs more smartly
authorFelix Krull <f_krull@gmx.de>
Wed, 22 May 2019 19:40:30 +0000 (21:40 +0200)
committerColin Walters <walters@verbum.org>
Fri, 6 May 2022 16:53:54 +0000 (12:53 -0400)
rust-bindings/rust/.gitlab-ci.yml

index 1a4e35908064b8141f2390743f1516f382b7e1c9..b3b8db667070c72df9cc51d49147967a90b9892f 100644 (file)
@@ -50,6 +50,7 @@ ostree_default_features:
     - cargo/
     - target/
 
+# canary until Debian Backports gets updated libostree
 ostree_all_features:
   stage: build
   script:
@@ -79,9 +80,19 @@ publish_ostree:
 # docs
 docs:
   stage: build
+  image: rustlang/rust:nightly
+  variables:
+    RUSTDOC_OPTS: >-
+      -Z unstable-options
+      --extern-html-root-url glib_sys=https://gtk-rs.org/docs
+      --extern-html-root-url gobject_sys=https://gtk-rs.org/docs
+      --extern-html-root-url gio_sys=https://gtk-rs.org/docs
+      --extern-html-root-url glib=https://gtk-rs.org/docs
+      --extern-html-root-url gio=https://gtk-rs.org/docs
   script:
   - make merge-lgpl-docs
-  - cargo doc --verbose --features dox
+  - cargo rustdoc --verbose --package ostree-sys --features dox -- ${RUSTDOC_OPTS}
+  - cargo rustdoc --verbose --package ostree --features dox -- ${RUSTDOC_OPTS}
   cache:
     paths:
     - cargo/
@@ -92,6 +103,7 @@ docs:
 
 pages:
   stage: publish
+  image: alpine
   script:
   - cp -r target/doc public
   artifacts: